from api.ihrm_emp_manage_api import IHRMEmpManageApi
from common.token_util import TokenUtil


class DepUtil:
    @classmethod
    def get_util_id(cls):
        token = TokenUtil.get_token()
        body = {"name": "test100", "code": "123456"}

        resp = IHRMEmpManageApi.add_emp_api(token, body)
        dep_id = resp.json().get("data").get("id")
        return dep_id


if __name__ == '__main__':
    print(DepUtil.get_util_id())
